import callApi from '../utils/request';
import {
  API_PAY_COUPON_LIST,
  API_CAL_COUPON,
  API_USER_COUPON_TOTAL,
  API_COUPON_LIST,
  API_CHECK_COUPON_DIALOG,
  API_GIFT_COUPON,
} from '../constants/api';

export function queryGiftStatus(params) {
  return callApi({
    api: API_CHECK_COUPON_DIALOG,
    params,
  });
}

export function getGiftPackage(params) {
  return callApi({
    api: API_GIFT_COUPON,
    params,
  });
}


export function queryCouponList(params) {
  return callApi({
    api: API_COUPON_LIST,
    params,
  });
}


export function queryPayCouponList(params) {
  return callApi({
    api: API_PAY_COUPON_LIST,
    params,
  });
}

export function queryUserCouponTotal(params) {
  return callApi({
    api: API_USER_COUPON_TOTAL,
    params,
  });
}


export function calCoupon(params) {
  return callApi({
    api: API_CAL_COUPON,
    params,
  });
}

